package vip.xiaonuo.bi.modular.dataset.enums;

/**
 * @auther: 顾育司
 * @Description doris符号常量 如 `>`, `=` 等设置
 * @date: 2024/1/6
 */
public enum DorisCanstant {
    // 等于
    EQ("eq","="),
    // 小于
    LT("lt","<"),
    // 大于
    GT("gt",">"),
    // 大于等于
    GE("ge",">="),
    // 小于等于
    LE("le","<="),
    // 不等于
    NE("ne","!="),
    // 是
    IS("is","="),
    // 不是
    NO("no","!="),
    // 包含
    LI("li","like"),
    // 不包含
    NL("nl","not like"),
    // 早于
    LT_D("lt","<"),
    // 晚于
    GT_D("gt",">"),
    //早于等于
    GE_D("ge",">="),
    // 晚于等于
    LE_D("le","<="),
    ;


    DorisCanstant(String filter, String val){
        this.filter = filter;
        this.val = val;
    }

    public static String getValue(String type){
        return valueOf(type.toUpperCase()).val;
    }

    // 筛选规则
    private String filter;

    // doris识别筛选规则
    private String val;
}
